package com.yoyo.yyadsdk.serv;

import android.app.ActivityManagerNative;
import android.app.IActivityManager;
import android.app.Service;
import android.content.Context;
import android.os.RemoteException;

import com.yoyo.yyadsdk.open.MyProcessObserver;

public class AppPullService {

    private Context mContext;

    public AppPullService(Service service) {
        mContext = service;
    }

    public void onCreate(){
        IActivityManager activityManager = ActivityManagerNative.getDefault();
        try {
            activityManager.registerProcessObserver(new MyProcessObserver(mContext));
        } catch (RemoteException e) {
            e.printStackTrace();
        }
    }
}
